package com.gxgeek.springbootwebfluxlearning.reposity;

import com.gxgeek.springbootwebfluxlearning.domain.User;
import org.springframework.data.repository.reactive.ReactiveCrudRepository;
import reactor.core.publisher.Mono;

/**
 * @author gaoxing
 * @create 2018-04-17 下午1:58
 */
public interface UserRepository extends ReactiveCrudRepository<User, String> {  // 1
    Mono<User> findByUsername(String username);     // 2
    Mono<Long> deleteByUsername(String username);
}
